define(()=>{
    return function(goodsMsg, c){
        for(let i=0;i<$(".checks").length;i++){
            // console.log($(".checks")[i])
            $(".checks")[i].checked = c;
        }
        goodsMsg.forEach(val=>{
            val.flag = Number(c)
        })
        localStorage.setItem("goodsMsg",JSON.stringify(goodsMsg))
    }
})